package com.leps.nq.login;

import com.leps.nq.sys.entity.SysRole;
import com.leps.nq.sys.vo.MenuInfoVo;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;

import java.util.List;

@ApiModel
public class LoginSuccessModel {
    @ApiModelProperty("token名称，登录成功之后的所有请求必须携带这个名称的请求头")
    public String tokenName;
    @ApiModelProperty("token值")
    public String tokenValue;
    @ApiModelProperty("用户拥有的角色")
    public List<SysRole> roles;
    @ApiModelProperty("用户拥有的菜单")
    public List<MenuInfoVo> menus;
    @ApiModelProperty("用户拥有的权限码")
    public List<String> perms;

    public LoginSuccessModel(String tokenName, String tokenValue, List<SysRole> roles, List<MenuInfoVo> menus, List<String> perms) {
        this.tokenName = tokenName;
        this.tokenValue = tokenValue;
        this.roles = roles;
        this.menus = menus;
        this.perms = perms;
    }
}
